<include file="Public:header" />
<div class="headbar">
    <div class="position"><span>系统</span><span>></span><span>权限管理</span><span>></span><span>管理员列表</span></div>
    <div class="operating">
        <a href="{:U('System/admin_edit')}" ><button class="operating_btn" type="button"><span class="addition">添加管理员</span></button></a>
        <a href="javascript:void(0)" onclick="selectAll('id[]');"><button class="operating_btn" type="button"><span class="sel_all">全选</span></button></a>
        <a href="javascript:void(0)" onclick="delModel({msg:'是否把信息放到回收站内？'});"><button class="operating_btn" type="button"><span class="delete">批量删除</span></button></a>
        <a href="javascript:void(0)" onclick="event_link('{url:/system/admin_recycle}')"><button class="operating_btn" type="button"><span class="recycle">回收站</span></button></a>
    </div>
</div>

<div class="content">
    <form name='admin_list' method='post' action="{:U('System/admin_update',array('recycle','del'))}">
        <table class="list_table">
            <colgroup>
                <col width="40px" />
                <col width="150px" />
                <col width="100px" />
                <col width="200px" />
                <col />
            </colgroup>

            <thead>
                <tr>
                    <th>选择</th>
                    <th>用户名</th>
                    <th>角色</th>
                    <th>Email</th>
                    <th>上次登录IP</th>
                    <th>上次登录时间</th>
                    <th>操作</th>
                </tr>
            </thead>

            <tbody>
                <foreach name='admin' item='item'>
                <tr>
                    <td><input type='checkbox' name='id[]' value="{$item['id']}" /></td>
                    <td>{$item['admin_name']}</td>
                    <td><if condition="$item.role_name neq null">{$item.role_name}<else/>超级管理员</if></td>
                    <td>{$item['email']}</td>
                    <td>{$item['last_ip']}</td>
                    <td>{$item['last_time']}</td>
                    <td>
                        <a href="{:U('System/admin_edit', array('id' => $item[id]))}"><img class="operator" src="__PUBLIC__/Operation/images/admin/icon_edit.gif" alt="编辑" title="编辑" /></a>
                        <a href='javascript:void(0)' onclick="delModel({link:'{:U('System/admin_update', array('recycle','del','id' => $item[id]))}',msg:'是否把信息放到回收站内？'});"><img class="operator" src="__PUBLIC__/Operation/images/admin/icon_del.gif" alt="删除" title="删除" /></a>
                    </td>
                </tr>
                </foreach>
            </tbody>
        </table>
    </form>
    {$page}
</div>
<include file="Public:footer" />